package net.stack;

public class Demo {
    public static void main(String[] args) {
        int sum=f(10);
        System.out.println(sum);
    }

    public static  int f(int x){
        if (x==1)
            return 1;
        return x+f(x-1);
    }
}
